<!DOCTYPE html>
<html lang="en">

<head>
    <meta charset="utf-8">
    <title>Index Of List</title>
</head>

<body>
    {# 显示 Flash Message #}
    {% for msg in get_flashed_messages() %}
    <div class="alert">{{ msg }}</div>
    {% endfor %}

    {# 加载静态文件 #}
    <img src="{{ url_for('static', filename='images/logo1.png')}}" height="50">
    
    {# 导入宏 sayhi #}
    {% from 'macros.html' import sayhi %}
    <h1>{{ foo }}, {{ bar }}, {{ sayhi(10) }}</h1>
    <a href="{{ url_for('watch_list') }}">View List</a>
    <hr>
    
    <div>
        {# 使用内置函数 #}
        {% for i in range(1, 5) %}
        {{ lipsum(n=1, html=True, min=10, max=50)|truncate(length=80, killwords=True, end='...') }}
        {% endfor %}

    </div>
    <hr>
    {# 使用过滤器 #}
    {{ '<h1>test</h1>'|escape }}
</body>

</html>